[U][COLOR=red][SIZE=7]    [/SIZE][/COLOR][/U]

           
               
    ..                       . ..                       ..  

[COLOR=red] :[/COLOR]    ..        
 [COLOR=blue]ADO[/COLOR]    . [COLOR=blue]    7[/COLOR]       
[COLOR=blue]2000 [/COLOR]

  [COLOR=blue] frmMain[/COLOR]

[COLOR=red][B] :     [/B][/COLOR] 

  [COLOR=blue] General [/COLOR]

[CODE]Dim cn As Connection
Dim rs1 As Recordset[/CODE]


[CODE]
Set cn = New Connection
Set rs1 = New Recordset
path = App.path & "\db1.mdb"
cn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & path & ";Persist Security Info=False"
rs1.Open "select * from customer", cn


[/CODE]

        

[CODE]
Private Sub Form_Load()
Set cn = New Connection
Set rs1 = New Recordset
Dim path As String
path = App.path & "\db1.mdb"
cn.Open "provider=microsoft.jet.oledb.4.0;data source=" & path & ";jet oledb:database password=NIM"
cn.CursorLocation = adUseClient

rs1.Open "select * from customer", cn, adOpenDynamic, adLockOptimistic

End Sub[/CODE]

      
  

[COLOR=red][B] :    Module1   [/B][/COLOR] 

[CODE]Declare Function CreateFieldDefFile Lib "p2smon.dll" (lpUnk As Object, _
ByVal filename As String, ByVal bOverWriteExistingFile As Long) _
As Long[/CODE]

            
   

 ...

[COLOR=red][B] :    [/B][/COLOR] 


  [COLOR=blue]project[/COLOR]      

[COLOR=blue]Crystal Report 8.5 [/COLOR]     
             
       ..      
 ...        [COLOR=blue]Form1 [/COLOR]    
 
[CODE]

Dim Report As New CrystalReport1

Private Sub Form_Load()
Screen.MousePointer = vbHourglass
CRViewer1.ReportSource = Report
CRViewer1.ViewReport
Screen.MousePointer = vbDefault

End Sub

Private Sub Form_Resize()
CRViewer1.Top = 0
CRViewer1.Left = 0
CRViewer1.Height = ScaleHeight
CRViewer1.Width = ScaleWidth

End Sub

[/CODE]

     [COLOR=red]Crystal Report Viewer control [/COLOR]

  ...           
     

[CODE]

Dim Report As New CrystalReport1
Dim cn As Connection
Dim rs1 As Recordset

Private Sub Form_Load()

Set cn = New Connection
Set rs1 = New Recordset
path = App.path & "\db1.mdb"
cn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & path & ";Persist Security Info=False"
rs1.Open "select * from customer", cn

Report.DiscardSavedData
Report.Database.SetDataSource rs1, 3, 1

CRViewer1.ReportSource = Report
CRViewer1.ViewReport
Screen.MousePointer = vbDefault

End Sub


Private Sub Form_Resize()
CRViewer1.Top = 0
CRViewer1.Left = 0
CRViewer1.Height = ScaleHeight
CRViewer1.Width = ScaleWidth

End Sub


[/CODE]


          

 

[COLOR=red][B] :   [/B][/COLOR]

    Form1    
 [COLOR=blue] Show Report

[CODE]'HnHn
'       
CreateFieldDefFile rs1, App.path & "\customer.ttx", 1
Form1.Show[/CODE]

        
[COLOR=blue]customer.ttx[/COLOR]         
    

      


         .... 


     